Class Topic
Handle to a topic obtained from Producer.
Inheritance
System.Object
Topic
Namespace:RdKafka
Assembly:cs.temp.dll.dll
Syntax
public class Topic : IDisposable
Properties
Name
Declaration
public string Name { get; }
Returns
Type | Description |
---|---|
System.String |
Methods
Dispose()
Declaration
public void Dispose()
PartitionAvailable(Int32)
Check if partition is available (has a leader broker).
Return true if the partition is available, else false.
This function must only be called from inside a partitioner function.
Declaration
public bool PartitionAvailable(int partition)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | partition |
Returns
Type | Description |
---|---|
System.Boolean |
Produce(Byte[], Byte[], Int32)
Declaration
public Task<DeliveryReport> Produce(byte[] payload, byte[] key = null, int partition = -1)
Parameters
Type | Name | Description |
---|---|---|
System.Byte[] | payload | |
System.Byte[] | key | |
System.Int32 | partition |
Returns
Type | Description |
---|---|
Task<DeliveryReport> |